package com.zareal.ymcc.dto;

import com.zareal.ymcc.util.AssertUtil;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;

@AllArgsConstructor
@NoArgsConstructor
@Data
public class RegisterUserDto {
    @Pattern(regexp = AssertUtil.PATTERN_PHONE,message = "手机号不正确")
    private String mobile;
    @Size(min = 6,max = 12,message = "密码长度范围为6-12")
    private String password;
    @NotNull
    private String smsCode;
    @NotNull
    private Integer regChannel;
}
